package cn.kgc.service;

import cn.kgc.dao.Gl_AppInfoDao;
import cn.kgc.pojo.AppCategory;
import cn.kgc.pojo.AppInfo;
import cn.kgc.pojo.AppVersion;
import cn.kgc.pojo.DataDictionary;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author:
 * @date: 2022/1/4
 * @description:
 */

@Service
public class Gl_AppInfoServiceImpl implements Gl_AppInfoService {

    @Resource
    private Gl_AppInfoDao glDao;

    @Override
    public boolean add(AppInfo appInfo) {
        if(glDao.add(appInfo)>0){
            return true;
        }
        return false;
    }

    @Override
    public AppInfo getAppInfo(Integer id, String APKName) {
        return glDao.getAppInfo(id,APKName);
    }

    @Override
    public List<DataDictionary> getDataDictionaryList(String typeCode) throws Exception {
        // TODO Auto-generated method stub
        return glDao.getDataDictionaryList(typeCode);
    }

    @Override
    public List<AppCategory> getAppCategoryListByParentId(Integer parentId) throws Exception {
        return glDao.getAppCategoryListByParentId(parentId);
    }

    @Override
    public List<AppVersion> getAppVersionList(Integer appId) throws Exception {
        return  glDao.getAppVersionList(appId);
    }


}
